package com.demo.service;

import java.util.List;
import java.util.Map;
import org.springframework.stereotype.Service;
import com.demo.bean.Asset;
import com.demo.bean.DongHuan;
import com.demo.bean.Event;

import net.sf.json.JSON;

/**
 * 产生各数据Json
 * 
 * @author LiaoMinJun
 *
 */
@Service
public interface JsonManageService {
	/**
	 * 随机产生架式设备，用于Tarsier
	 * 
	 * @param Assetlist
	 * @param Racklist
	 * @param DCID
	 * @param J
	 * @param G
	 * @return
	 */
	public JSON JsonDataManage(List<Asset> Assetlist, List<String> Racklist, int J, int G);

	/**
	 * 随机产生架式设备，用于ITVOP
	 * 
	 * @param Assetlist
	 * @param Racklist
	 * @param DCID
	 * @param J
	 * @param G
	 * @return
	 */
	public JSON JsonManage(List<Asset> Assetlist, List<String> Racklist, String DCID, int J, int G);

	/**
	 * 随机产生监控数据
	 * 
	 * @param donghuanmap
	 * @return
	 */
	public JSON donghuanManage(Map<String, List<String>> donghuanmap, String path);

	public Map<String, List<String>> shebeilistMange(String peidiangui, String wenshidu, String kongtiao, String UPS,
			String fadianji);

	/**
	 * 随机产生告警数据，用于itvop
	 * 
	 * @param eventlist
	 * @return
	 */
	public List<JSON> eventManage(List<String> eventlist, String path);

	/**
	 * 随机产生告警数据，用于TARSIER
	 * 
	 * @param eventlist
	 * @return
	 */
	public List<JSON> eventManages(List<String> eventlist, String content, String path);

	/**
	 * 产生服务器监控数据,用于Tarsier
	 * 
	 * @param fuwuqiperfManage
	 * @return
	 */
	public JSON fuwuqiperfManage(List<String> cilist, List<String> kpilist);

	/**
	 * 读取预设值参数
	 * 
	 * @return DongHuan对象动环模拟推送的范围
	 */
	public DongHuan readPerfSetUpJson(String path);

	public boolean writePerfSetUpJson(String path, DongHuan dongHuan);

	/**
	 * 读取预设值参数
	 * 
	 * @return 告警对象动环模拟推送的范围
	 */
	public Event readEventSetUpJson(String path);

	public boolean writeEventSetUpJson(String path, Event event);
}
